package com.tyk.bookstore.front.order.model.result;


import com.tyk.bookstore.front.common.core.model.result.ResultEnum;

public enum OrderResultEnum implements ResultEnum {
    ORDER_NOT_FOUND(4_06_01_01, "订单不存在"),
    NO_PRODUCT_SELECTED(4_06_01_02, "未选择商品"),
    STOCK_NOT_MEET(4_06_01_03, "库存不足"),
    ORDER_HAS_COMMITTED(4_06_01_04, "订单已提交"),
    ORDER_REPEAT_COMMIT(4_06_01_05, "订单重复提交"),
    ORDER_SPLIT_MODE_UNSUPPORTED(4_06_01_06, "拆单方式不支持"),
    STATE_NOT_SUPPORT_CANCEL(4_06_01_07, "当前状态不支持取消订单"),
    ORDER_HAS_PAID_OR_CANCEL(4_06_01_08, "订单已支付或已取消"),
    ORDER_NOT_END(4_06_01_09, "订单未完成");

    private final Integer code;
    private final String msg;

    @Override
    public Integer getCode() {
        return this.code;
    }

    @Override
    public String getMsg() {
        return this.msg;
    }

    OrderResultEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
